﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace wmdata
{
    public partial class post : Form
    {
        public post(DataRow[] parow, DataRow prow, HtmlElement poldpass, HtmlElement pnewpass, HtmlElement pnewpass2)
        {
            this.Load += new EventHandler(post_Load);
            row = parow;
            newrow = prow;
            oldpass = poldpass;
            newpass = pnewpass;
            newpass2 = pnewpass2;
        }

        void post_Load(object sender, EventArgs e)
        {
            oldpass.SetAttribute("value", row[0]["pass"].ToString());
            newpass.SetAttribute("value", newrow["pass"].ToString());
            newpass2.SetAttribute("value", newrow["pass"].ToString());
            
            
            
            
            
            postform.DocumentCompleted += new WebBrowserDocumentCompletedEventHandler(postform_DocumentCompleted);
            postform.AllowNavigation = true;
            postform.Navigate("https://wmt.quickbase.com/db/main?a=DoProfilePasswordChange", false);
        }

        void postform_DocumentCompleted(object sender, WebBrowserDocumentCompletedEventArgs e)
        {
            
        }

        WebBrowser postform = new WebBrowser();
        DataRow[] row;
        DataRow newrow;
        HtmlElement oldpass;
        HtmlElement newpass;
        HtmlElement newpass2;        
    } 
}
